package com.consumer.client;

import com.consumer.client.impl.ProducerFeignImplHystrix;
import com.consumer.entity.UserEneity;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;

@FeignClient(name = "producer",fallback = ProducerFeignImplHystrix.class)  // 生产者的服务名称
public interface ProducerFeign {

    @GetMapping("/user/all")
    List<UserEneity> getAll();

}
